//
//  ViewController.m
//  10505slidercontol
//
//  Created by 小白 on 16/2/19.
//  Copyright © 2016年 小白. All rights reserved.
//

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
- (IBAction)slideraction:(id)sender {
    //把用label显示slider的数值
    self.labelred.text = [NSString stringWithFormat:@"%f", self.sliderred.value];
    self.labelGreen.text = [NSString stringWithFormat:@"%f", self.slidergreen.value];
    self.labelBlue.text = [NSString stringWithFormat:@"%f", self.sliderblue.value];
    //用uicolor属性red blue green
    self.imagebackground.backgroundColor = [UIColor colorWithRed:self.sliderred.value green:self.slidergreen.value blue:self.sliderblue.value alpha:1];
    
}

@end
